<script src="/js/jquery.min.js?v=2.1.4"></script>
<script src="/js/bootstrap.min.js?v=3.3.6"></script>
<script src="/js/plugins/metisMenu/jquery.metisMenu.js"></script>
<script src="/js/plugins/slimscroll/jquery.slimscroll.min.js"></script>
<script src="/js/plugins/layer/layer.min.js"></script>
<script src="/js/hplus.min.js?v=4.1.0"></script>
<script src="/js/contabs.min.js"></script>
<script src="/js/plugins/pace/pace.min.js"></script>
<script src="/js/content.min.js?v=1.0.0"></script>
<script src="/js/plugins/layer/layer.min.js"></script>
<script src="/js/plugins/validate/jquery.validate.min.js"></script>
<script src="/js/plugins/validate/messages_zh.min.js"></script>
<script src="/js/ajaxfileupload.js"></script>
<script type="text/javascript">
	(function(window, layer) {
		var wxLayer = {};
		wxLayer.alert = function(title, callback) {
			parent.layer.alert(title, function(index) {
				parent.layer.close(index);
				if (callback)
					callback();
			});
		}

		wxLayer.confirm = function(title, okCallback, cancelCallback) {
			parent.layer.confirm(title, function(index) {
				parent.layer.close(index);
				if (okCallback)
					okCallback();
			}, function(index) {
				parent.layer.close(index);
				if (cancelCallback)
					cancelCallback();
			});
		}
		window.wxLayer = wxLayer;
	})(window, layer);

	$(function() {
		$.validator.setDefaults({
			highlight : function(e) {
				$(e).closest(".form-group").removeClass("has-success")
						.addClass("has-error")
			},
			success : function(e) {
				e.closest(".form-group").removeClass("has-error").addClass(
						"has-success")
			},
			errorElement : "span",
			errorPlacement : function(e, r) {
				e.appendTo(r.is(":radio") || r.is(":checkbox") ? r.parent()
						.parent().parent() : r.parent())
			},
			errorClass : "help-block m-b-none",
			validClass : "help-block m-b-none"
		})
	})
	$(function() {
		$("li.page_index a").click(function() {
			goPage($(this).data("index"));
		})
	})
	function goPage(pageNo){
		$("#searchForm input[name='pageNo']").remove();
		// 带页码参数
		var _pageNo = $('<input type="hidden" name="pageNo" />');
		_pageNo.val(pageNo);
		$("#searchForm").append(_pageNo);
		$("#searchForm").submit();
	}
</script>